from selenium.webdriver.common.by import By

from base import Base
class Page(Base):
    def dian(self):
        loc=(By.ANDROID_UIAUTOMATOR,'new UiSelector().text("减脂")')
        ele=self.find_ele(loc)
        return ele
    def zaocan(self):
        loc=(By.XPATH,'//android.widget.TextView[@text="早餐"]')
        ele=self.find_ele(loc)
        return ele
    def xinyonghu(self):
        loc=(By.ID,'com.xiachufang:id/tv_join')
        ele=self.find_ele(loc)
        return ele
    def kuang(self):
        loc=(By.CLASS_NAME,'android.widget.CheckBox')
        ele=self.find_ele(loc)
        return ele
    def fan(self):
        loc=(By.ACCESSIBILITY_ID,'返回')
        ele=self.find_ele(loc)
        return ele
    def duanyan(self):
        loc=(By.XPATH,'//android.widget.TextView[@resource-id="android:id/text1" and @text="商店"]')
        ele=self.find_ele(loc)
        return ele
    def duanyan1(self):
        loc=(By.XPATH,'//android.widget.TextView[@resource-id="android:id/text1" and @text="分类"]')
        ele=self.find_ele(loc)
        return ele
